"""
数据类
"""

from pydantic import BaseModel


class ResponseData(BaseModel):
    code: int = 200
    data: dict


class SqlError(BaseModel):
    code: int = 40001
    error: dict = {"error": "数据库查询错误"}


class DrawFullError(BaseModel):
    code: int = 40002
    error: dict = {"error": "抽奖人数已满"}


class NoAuthorizedError(BaseModel):
    code: int = 40003
    error: dict = {"error": "未授权"}


class LuckyDrawWithParam(BaseModel):
    token: str